from random import *
from graph import *
x0= 150
y0= 250
polygon([[143,242],[155,242],[155,255],[143,255]])
penColor("red")
penSize(3)
n=int(input('n='))
if n<=0:
    print('введите число больше нуля')
    n=int(input('n='))
c=0
for i in range(n):
    x=randint(50,250)
    y=randint(150,350)
    point(x,y)
    if 155>x>143 and 242<y<255:
        c+=1
print(c)
run()
